#!/usr/bin/perl -w

use strict;

open(LOG, "darcs changes|") || die "Can't open 'dk changes': $!";

my $lastDate = "";
while(<LOG>)
{
    if( /^(\w+)\s+(\w+)\s+(\d+)\s+([0-9:]+)\s+(\w+)\s+(\d+)\s+(.*)$/ )
    {
	my $date = "$1 $2 $3 $6";
	if($date ne $lastDate)
	{
	    $lastDate = $date;
	    print "$date $7\n";
	}
    } else
    {
	s/^\s+//;
	if(/\w/)
	{
	    print "\t$_";
	} else
	{
	    #print "\n";
	}
    }
}

close(LOG)

